package com.smiier.skin.ui;

import android.content.Context;
import android.util.AttributeSet;
import cn.o.app.ui.OStateViewFrame;
import cn.skinapp.R;

import com.smiier.skin.utils.CommonUtility;

public class PersonalFragment extends BasicFragment {

	protected OStateViewFrame mFrame;

	public PersonalFragment(Context context) {
		super(context);
	}

	public PersonalFragment(Context context, AttributeSet attrs) {
		super(context, attrs);
	}

	public PersonalFragment(Context context, AttributeSet attrs, int defStyle) {
		super(context, attrs, defStyle);
	}

	@Override
	public void onCreate() {
		super.onCreate();
		this.setContentView(R.layout.fragment_personal);

		mFrame = findViewById(R.id.frame, OStateViewFrame.class);
	}

	@Override
	public void onStart() {
		super.onStart();

		if (CommonUtility.isDoctor()) {
			mFrame.setSelectedIndex(0);
		} else {
			mFrame.setSelectedIndex(1);
		}
	}
}
